<!--
 * @Descripttion:
 * @version: 1.0.0
 * @Author: lai_hq@qq.com
 * @Date: 2022-07-30 13:38:03
 * @LastEditors: lai_hq@qq.com
 * @LastEditTime: 2022-08-05 16:56:42
-->
<template>
    <div>
        {{ state.current }}

        <button @click="add">Add</button>

        <a-button type="primary">Primary Button</a-button>
        <a-button>Default Button</a-button>
        <a-button type="dashed">Dashed Button</a-button>
        <a-button type="text">Text Button</a-button>
        <a-button type="link">Link Button</a-button>
    </div>
</template>
<script setup lang="ts">
// Fetch the computer's MAC address for a specific interface

// Validate that an address is a MAC address

import { login } from '@/api/users'

console.log(import.meta.env.VITE_BASE_API)

console.log(import.meta.env.MODE)

onMounted(() => {})

const state = reactive({
    current: 1222
})

function add() {
    // console.log(router)
    state.current += 2

    const params = {
        username: 'admin_401275',
        password: '401275',
        grant_type: 'password',
        client_id: 'yide-cloud',
        client_secret: 'yide1234567'
    }
    login(params).then((res) => {
        console.log(res)
    })
}

//
</script>
<style scoped lang="less">
.home {
    color: red;
    position: absolute;
    margin-bottom: 10px;
    left: 20;
}
</style>
